package interfaces;

import java.awt.Color;
import java.awt.FlowLayout;

import javax.swing.ImageIcon;
import javax.swing.JButton;
import javax.swing.JDesktopPane;
import javax.swing.JFrame;
import javax.swing.JLabel;
import javax.swing.JPanel;
import javax.swing.WindowConstants;

public class Welcome extends JFrame {
        private JButton agenda;
        private JButton usuario;
        private JButton fechar;
        private JButton logoff;
        private JPanel painel1;
        private JPanel painelglobal;
        private JLabel labelppg;
        private JLabel netbeanssux;
        private JDesktopPane desktop;


        public Welcome(){

                JFrame janelawelcome = new JFrame("Welcome PPG AGENDA !");
                janelawelcome.setSize(815,650);
                janelawelcome.setUndecorated(false);
        FlowLayout layoutc = new FlowLayout(FlowLayout.CENTER);

        //label
        labelppg = new JLabel(new ImageIcon("src/images/ppg2.jpg"));
        labelppg.setBounds(0,30,800,600);
        //Desktop
        desktop = new JDesktopPane();
        desktop.setBackground(Color.WHITE);
        netbeanssux = new JLabel("NetBeans � para os fracos.   By: PPG Team.");
        netbeanssux.setBounds(550,550,400,100);
                //Butoes

                agenda = new JButton("Agenda");
                agenda.setIcon(new
                                ImageIcon("src/images/agenda.png"));
                agenda.setBounds(1,1,150,100);
                agenda.setBackground(Color.WHITE);

                usuario = new JButton("Perfil");
                usuario.setIcon(new
                                ImageIcon("src/images/user.png"));
                usuario.setBounds(150,1,150,100);
                usuario.setBackground(Color.WHITE);


                fechar = new JButton("Fechar");
                fechar.setIcon(new
                                ImageIcon("src/images/fechar.png"));
                fechar.setBounds(675,1,133,100);
                fechar.setBackground(Color.WHITE);

                logoff = new JButton("LogOFF");
                logoff.setBounds(525,1,150,100);
                logoff.setIcon(new
                                ImageIcon("src/images/logoff.png"));
                logoff.setBackground(Color.WHITE);

                //paineis
                painel1 = new JPanel(layoutc);
                painelglobal = new JPanel(layoutc);

                //adds
                desktop.add(agenda);
                desktop.add(usuario);
                desktop.add(fechar);
                desktop.add(logoff);
                desktop.add(labelppg);
                desktop.add(netbeanssux);
                janelawelcome.setContentPane(desktop);
        janelawelcome.setResizable(false);

        janelawelcome.setVisible(true);
        janelawelcome.setDefaultCloseOperation( WindowConstants.
                       EXIT_ON_CLOSE);

        }
        public static void main(String[] args){
                Welcome welcome = new Welcome();
        }
}
 